﻿using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace SanJ.FreeCare.Migrations
{
    /// <inheritdoc />
    public partial class addDisease : Migration
    {
        /// <inheritdoc />
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.RenameColumn(
                name: "description",
                table: "fc_ConditionDefinitions",
                newName: "MedicalInterpretation");

            migrationBuilder.AddColumn<string>(
                name: "Classification",
                table: "fc_ConditionDefinitions",
                type: "longtext",
                nullable: true)
                .Annotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AddColumn<int>(
                name: "ClassificationOder",
                table: "fc_ConditionDefinitions",
                type: "int",
                nullable: false,
                defaultValue: 0);

            migrationBuilder.AddColumn<string>(
                name: "CommonCause",
                table: "fc_ConditionDefinitions",
                type: "longtext",
                nullable: false)
                .Annotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AddColumn<string>(
                name: "DtSuggest",
                table: "fc_ConditionDefinitions",
                type: "longtext",
                nullable: false)
                .Annotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AddColumn<bool>(
                name: "Gender",
                table: "fc_ConditionDefinitions",
                type: "tinyint(1)",
                nullable: false,
                defaultValue: false);

            migrationBuilder.AddColumn<bool>(
                name: "Notification",
                table: "fc_ConditionDefinitions",
                type: "tinyint(1)",
                nullable: false,
                defaultValue: false);

            migrationBuilder.AddColumn<int>(
                name: "Order",
                table: "fc_ConditionDefinitions",
                type: "int",
                nullable: true);

            migrationBuilder.AddColumn<string>(
                name: "PermittedDataType",
                table: "fc_ConditionDefinitions",
                type: "longtext",
                nullable: true)
                .Annotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AddColumn<string>(
                name: "PermittedUnit",
                table: "fc_ConditionDefinitions",
                type: "longtext",
                nullable: true)
                .Annotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AddColumn<string>(
                name: "Spell",
                table: "fc_ConditionDefinitions",
                type: "longtext",
                nullable: true)
                .Annotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AddColumn<string>(
                name: "Suifang",
                table: "fc_ConditionDefinitions",
                type: "longtext",
                nullable: true)
                .Annotation("MySql:CharSet", "utf8mb4");

            migrationBuilder.AddColumn<double>(
                name: "SuifangCycle",
                table: "fc_ConditionDefinitions",
                type: "double",
                nullable: true);
        }

        /// <inheritdoc />
        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropColumn(
                name: "Classification",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "ClassificationOder",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "CommonCause",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "DtSuggest",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "Gender",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "Notification",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "Order",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "PermittedDataType",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "PermittedUnit",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "Spell",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "Suifang",
                table: "fc_ConditionDefinitions");

            migrationBuilder.DropColumn(
                name: "SuifangCycle",
                table: "fc_ConditionDefinitions");

            migrationBuilder.RenameColumn(
                name: "MedicalInterpretation",
                table: "fc_ConditionDefinitions",
                newName: "description");
        }
    }
}
